
#include <cstdio>
#include <BFont>
#include <BApplication>
#include <BTcpSocket>
#include <BTcpServer>
#include "MainWindow.h"

class ServerManager
{
public:
	ServerManager(BTcpServer* server)
	{

	}
	~ServerManager()
	{

	}

private:
	void procNewConnection(BObject* object)
	{

	}

};
int main(int argc, char** argv)
{
	BFont* font = new BFont("font/times.ttf");
	BApplication app(argc, argv);

	BTcpServer* server = new BTcpServer();
	server->bind("192.168.1.0", 123);
	server->listen(123);

	BTcpSocket socket;
	bool ret = socket.connect("192.168.1.0", 123);

	MainWindow mw;
	mw.setFont(font);
	mw.setSize(200, 150);
	mw.show();
	
	return app.execute();
}
